subItemClick
Type
message
Summary
This message is sent when the user clicks a subitem.
Syntax
subItemClick (pItemIndex, pSubItemName, pMouseButton)
Description
Use the subItemClick message to detect when the user clicks on a specific subitem.
Parameters
Name | Type | Description |
---|---|---|
pItemIndex | An Integer representing the index of the item under the mouse cursor. | |
pSubItemName | A String representing the name of the subitem under the mouse cursor. | |
pMouseButton | An integer identifying the mouse button generated the event. |
Examples
on subItemClick pItemIndex, pSubItemName
if pSubItemName is "heart" then
set the itemPointer of me to pItemIndex
set the subItemPointer of me to pSubItemName
local tCurrentVal
put the subItemContent of me into tCurrentVal
if tCurrentVal is "#255,90,95#heart" then
set the subItemContent of me to "#255,255,255#heart empty"
else
set the subItemContent of me to "#255,90,95#heart"
end if
end if
end subItemClick